import http from "@/utils/http";
import {XG_PATH,GW} from "@/common/const";

/**
 * 我的预警列表
 * @param {Object} 
 */
export function getInfoList(option) {
  const url = `${GW}/smonitor/stock/info/list`;
  const params = {
    ...option,
  };
  return http.get(url, params );
}

/**
 * 形态指标数据
 */
export function getFeeds(option) {
  const url = `${XG_PATH}/searchserver/api/mystock/feeds.htm`;
  const params = {
    ...option,
  };
  return http.get(url,  params );
}

/**
 * 历史监控list
 * @param {Number} option.userId - 用户ID
 * @param {Number} option.alertDataType - 数据类型  自选股价预警:101  指标 102  形态 103
 * @param {Number} option.limit - 请求条数
 * @return {Promise} Array
 */
export function getHistoryList(option) {
  const url = `${GW}/smonitor/stock/record/list`;
  const params = {
    ...option,
  };
  return http.get(url,  params );
}
